from django.conf.urls import url

from . import views


urlpatterns = [
    # 跳转更改密码页
    url(r'^find_password/$', views.FindPassword.as_view()),
    # 验证用户是否存在
    url(r'^accounts/(?P<username>[a-zA-Z0-9_-]{5,20})/sms/token/$', views.AccountsUsername.as_view()),
    # 获取短信验证码
    url(r'^find_password_sms_codes/(?P<mobile>1[3-9]\d{9})/$', views.SmsCodes.as_view()),
    # 验证短信验证码
    url(r'^accounts/(?P<mobile>[a-zA-Z0-9_-]{5,20})/password/token/$', views.AccountsSmsCodes.as_view()),
    # 重置密码
    url(r'^users/(?P<user_id>\d+)/new_password/$', views.ResettingPassword.as_view()),
]
